Heretofore, with a system or the like for transmitting a moving image or recording this in a recording medium, high-efficiency encoding has been carried out to take advantage of a transmission path or recording capacity effectively. With an image encoding device for realizing this, the encoding bit rate of a bit stream generated at an encoder is set to be a certain rate according to the transfer rate of a transmission medium, and under this restriction, a data generated quantity, i.e., the quantizing step of quantization at the encoder is controlled. That is to say, the image encoding device suppresses the data generated quantity by increasing the quantizing step, for example, when images having a complicated picture pattern continue, and conversely, when picture images having a simple picture pattern continue, a fixed rate is held so as not to cause overflow or underflow of buffer memory by reducing the quantizing step and increasing a data generated quantity.
Accordingly, with an image encoding device according to such a conventional technique, when complicated images continue, the quantizing step increases, and image quality deteriorates, and when simple images continue, the quantizing step decreases, and uniform image quality is not available as a whole. In the light of this problem, for example, with Patent Document 1, an image encoding device has been disclosed wherein an assigned code quantity to be assigned to each GOP itself in accordance with the ratio of sum of encoding difficulty for each GOP (Group Of Pictures), and encoding difficulty for multiple GOPs, is assigned more to a GOP including an image having a complicated picture pattern, and is assigned less to a GOP including an image having a simple picture pattern.
On the other hand, as a method for adding a generated code quantity to the target code quantity given to one picture, for example, the step 2 of TM5 (test model 5) has been known well. This is a technique wherein the code quantity assigned to a picture distributed to macro blocks (MB; Macro block) is taken as the target code quantity of the MBs, and feedback control is applied within the picture.
Also, with the encoding processing of a redundant compressing method such as MPEG or the like, the image encoding device executes quantization processing after subjecting to orthogonal transform such as DCT (Discrete Cosine Transform) or the like, thereby executing processing for reducing information volume. Subsequently, the image encoding device controls the value of this quantization to execute control of code quantity. At this time, a monotonous reduction relationship holds between the quantization parameters and the generated code quantity. Therefore, the image encoding device computes a code quantity with the quantizing value of an appropriate interval, and subjects the predictive value of the code quantity positioned in the intermediated thereof to linear interpolation, or the like, whereby the generated code quantity can be predicted (binary search or the like to be executed with intra VTR such as DV or the like).
This method may be applied to not only an encoding method using a fixed table such as MPEG2 or the like but also a context adaptive encoding method used for AVC or the like.
Patent Document 1: Japanese Patent No. 3358620
However, with the above method in the step 2 of TM5, with encoding of a first picture in a sequence or a picture immediately after change in scenes, the initial value of the quantizing step is unmatched with the picture pattern of the picture thereof, and accordingly, there are cases where image quality deteriorates.
For example, with the method in the step 2 of TM5, with the image encoding device, in the case that the quantizing step of a portion up to where feedback follows the picture pattern is too great, the image quality of the portion thereof will be deteriorated as compared to other portions, and in the case that the quantized value is too small, the code quantity is excessively used at this portion, which may affect other portions.
Also, with the image encoding device, the target code quantity of MBs is set to be a certain code quantity constantly, and accordingly, inappropriate code quantity distribution is caused when there is a deviation regarding image difficulty within the screen, or the like.
Accordingly, it is an object of the present invention to suppress the generated code quantity for each image increment below the target code quantity in a sure manner without the usage quantizing factor, serving as the basis of the quantizing step, deviating greatly.